/* sample program using distance.g */

new;
rndseed 1;

n=30;
k=3;
x=rndn(n,k);
z=zeros(1,k)|(zeros(1,k)+8); @ two query points @

declare external matrix _distance_vx;

_distance_d="dist";
d=distance(z,x);
"dist:"; d;?;

_distance_d="frac";
d=distance(z,x);
"frac: (_distance_alpha=V(X))"; d;?;

_distance_alpha=.1;
d=distance(z,x);
"frac: (_distance_alpha=.1)"; d;?;

_distance_d="prox";
d=distance(z,x);
"prox:"; d;?;

"v(x):"; _distance_vx; ?;
